from langgraph.graph import StateGraph,START,END
from typing_extensions import TypedDict

class State(TypedDict):
    user_input:str
class ReturnNodeValue:
    def __init__(self,node_secret:str):
        self._value = node_secret

    def __call__(self, state:State):
        return {"aggretate":self._value}

builder = StateGraph(State)
builder.add_node("a",ReturnNodeValue("I'm a"))
builder.add_node("b",ReturnNodeValue("I'm b"))
builder.add_node("c",ReturnNodeValue("I'm c"))
builder.add_node("d",ReturnNodeValue("I'm d"))
builder.add_edge(START,"a")
builder.add_edge("a","b")
builder.add_edge("a","c")
builder.add_edge("a","d")
builder.add_edge("d",END)
graph = builder.compile()